package com.hcg.spring_002.controller;

import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * 全局异常
 */
@RestController
@RequestMapping("/catch")
public class OverAllAbnormalController {

    @RequestMapping("/try")
    public String catcherror(Integer i){
        Integer j = 1/i;
        return j.toString();

    }
}
